# Contributor: David Demelier <markand@malikania.fr>
# Maintainer: David Demelier <markand@malikania.fr>
pkgname=cog
pkgver=0.18.3
pkgrel=1
pkgdesc="simple browser for WebKit WPE"
url="https://github.com/Igalia/cog"
arch="all"
license="MIT"
makedepends="
	cairo-dev
	coreutils
	eudev-dev
	libepoxy-dev
	libinput-dev
	libmanette-dev
	libsoup3-dev
	libwpebackend-fdo-dev
	mesa-dev
	meson
	wayland-dev
	wayland-protocols
	weston-dev
	wpewebkit-dev
	"
subpackages="$pkgname-dev $pkgname-doc"
source="https://github.com/Igalia/cog/releases/download/$pkgver/cog-$pkgver.tar.xz
	libweston-14-protocols.patch
	"
options="!check" # no tests

build() {
	abuild-meson \
		-Db_lto=true \
		-Dwayland_weston_direct_display=true \
		. output

	meson compile -C output
}

package() {
	DESTDIR="$pkgdir" meson install --no-rebuild -C output
}

sha512sums="
3dd5c08e84cedf7af15ed42f8d76aa28132f616aa9692760d7b3d04fdb12d57a66ee9f46ab6d7f02290ba9da37c07b8f6fbf90d03b09836adb8691289a614651  cog-0.18.3.tar.xz
679d0bfd04027ec32d632f0be62c766d0f17572049b5bed4304e688b3bd20b15de79084fcd4c5126277f1dc80abd157790e6633ba4581c1578d7bdd077cd7119  libweston-14-protocols.patch
"
